<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <title>{{htmlTitle}}</title>
    <link href="{{_G['APP']}}/resource/css/install.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="{{_G['APP']}}/resource/js/jquery.js"></script>
    <script>
        $(document).ready(function(){
            $('#next').on('click',function(){
                if (typeof($('.no').html()) == 'undefined'){
                    $(this).attr('href',"{{G.url('install/index/select')}}");
                }else{
                    alert($('.no').eq(0).parent().parent().find('td:first').html()+' 未通过检测!');
                    $(this).attr('href','###');
                }
            });
        });
    </script>
</head>
<body>
{{ include("common/header.html")}}
<div class="main">
    <div class="step-box" id="step1">
        <div class="text-nav">
            <h1>Step.1</h1>
            <h2>开始安装</h2>
            <h5>检测服务器环境及文件目录权限</h5>
        </div>
        <div class="procedure-nav">
            <div class="schedule-ico"><span class="a"></span><span class="b"></span><span class="c"></span><span class="d"></span></div>
            <div class="schedule-point-now"><span class="a"></span><span class="b"></span><span class="c"></span><span class="d"></span></div>
            <div class="schedule-point-bg"><span class="a"></span><span class="b"></span><span class="c"></span><span class="d"></span></div>
            <div class="schedule-line-now"><em></em></div>
            <div class="schedule-line-bg"></div>
            <div class="schedule-text"><span class="a">检查安装环境</span><span class="b">选择安装方式</span><span class="c">创建数据库</span><span class="d">安装</span></div>
        </div>
    </div>
    <div class="content-box">
        <table width="100%" border="0" cellspacing="2" cellpadding="0">
            <caption>
                环境检查
            </caption>
            <tr>
                <th scope="col">环境名称</th>
                <th width="25%" scope="col">程序所需</th>
                <th width="25%" scope="col">最佳配置推荐</th>
                <th width="25%" scope="col">当前服务器</th>
            </tr>
            {% for data in envTtems%}

            <tr>
                <td scope="row">{{data.name}}</td>
                <td>{{data.min}}</td>
                <td>{{data.good}}</td>
                <td><span class="{% if data.status %} yes {% else %} no{% endif %}"><i></i>{{data.cur}}</span></td>
            </tr>
            {% endfor %}
        </table>
        <table width="100%" border="0" cellspacing="2" cellpadding="0">
            <caption>
                目录、文件权限检查
            </caption>
            <tr>
                <th scope="col">目录文件</th>
                <th width="25%" scope="col">所需状态</th>
                <th width="25%" scope="col">当前状态</th>
            </tr>
            {% for data in dirfileTtems %}
            <tr>
                <td>{{data.path}} </td>
                <td><span>可写</span></td>
                <td><span class="{% if data.status %} yes {% else %} no{% endif %}"><i></i>
                    {% if data.status %} 可写 {% else %} 不可写 {% endif %}
                    </span></td>
            </tr>
            {% endfor %}
        </table>
        <table width="100%" border="0" cellspacing="2" cellpadding="0">
            <caption>
                函数检查
            </caption>
            <tr>
                <th scope="col">函数名称</th>
                <th width="25%" scope="col">所需状态</th>
                <th width="25%" scope="col">当前状态</th>
            </tr>
            {% for data in funcItems %}

            <tr>
                <td>{{data.name}}()</td>
                <td><span>支持</span></td>
                <td><span class="{% if data.status==1 %} yes {% else %} no{% endif %}"><i></i>
                     {% if data.status==1 %} 支持 {% else %} 不支持 {% endif %}
                </span></td>
            </tr>
            {% endfor %}
        </table>
        <table width="100%" border="0" cellspacing="2" cellpadding="0">
            <caption>
                PHP扩展检查
            </caption>
            <tr>
                <th scope="col">扩展名称</th>
                <th width="25%" scope="col">所需状态</th>
                <th width="25%" scope="col">当前状态</th>
            </tr>
            {% for data in extensionItems %}

            <tr>
                <td>{{data.name |upper}}</td>
                <td><span>支持</span></td>
                <td><span class="{% if data.status==1 %} yes {% else %} no{% endif %}"><i></i>
                     {% if data.status==1 %} 支持 {% else %} 不支持 {% endif %}
                </span></td>
            </tr>
            {% endfor %}
        </table>
    </div>
    <div class="btn-box"><a href="{{G.url('install/index/index')}}" class="btn btn-primary">上一步</a><a href='###' id="next" class="btn btn-primary">下一步</a></div>
</div>
{{ include("common/footer.html")}}
</body>
</html>
